<?php

namespace App\Common\DB\Pool;

use App\Common\DB\CommonMysql;
use App\X\EHelper;
use EasySwoole\Component\Pool\AbstractPool;

class PoolMysql extends AbstractPool
{
    /**
     * 请在此处返回一个数据库链接实例
     * @return CommonMysql
     */
    protected function createObject()
    {
        $conf = EHelper::funcGetConf("MYSQL");
        $dbConf = new \EasySwoole\Mysqli\Config($conf);

        return new CommonMysql($dbConf);
    }
}